package com.sh.cloudrender.infrastructure.repository;

import com.sh.cloudrender.application.dto.access.AccessDTO;

import java.util.List;

public interface AccessRepo {

    boolean save(String userId, AccessDTO accessDTO);

    List<AccessDTO> findByUserId(String userId);

    AccessDTO findByKey(String userId, String accessKey);

    boolean deleteByUserId(String userId);

    boolean disableByKey(String userId, String accessKey);

    boolean updateLastUsedTime(String userId, String accessKey);

    List<AccessDTO> getAccessKeyByEngineId(String engineId);
}
